package im.engure.provider;

import im.engure.common.protocol.ProtocolFactory;
import im.engure.common.registery.LocalServiceRegistry;
import im.engure.common.registery.URL;
import im.engure.provider.serviceimpl.QuotesServiceImpl;

public class Provider {
    public static void main(String[] args) {

        //“注册服务”
        LocalServiceRegistry.registerService("im.engure.common.service.QuotesService",
                QuotesServiceImpl.class);

        //启动服务
        //new HttpServer().start("127.0.0.1", 8888);
        //通过协议工厂获取所配置的协议
        ProtocolFactory.getProtocol().start(new URL("127.0.0.1", 8888));
    }
}
